package com.ruoyi.project.oms.paeaRiskItem.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.project.oms.paeaAuAuditFifldInfo.domain.PaeaAuAuditFifldInfo;
import com.ruoyi.project.oms.paeaAuType.domain.PaeaAuType;
import com.ruoyi.project.oms.paeaRiskItem.domain.PaeaRiskItem;
import com.ruoyi.project.oms.paeaRiskItem.domain.PaeaRiskItemNumModel;
import com.ruoyi.project.oms.paeaRiskItem.domain.PaeaRiskItemQuery;
import com.ruoyi.project.oms.paeaRiskItemDetail.domain.PaeaRiskItemDetail;
import com.ruoyi.project.system.user.domain.User;
import org.springframework.ui.ModelMap;

import java.util.Date;
import java.util.List;

/**
 * 预警Service接口
 *
 * @author gang.wei
 * @date 2020-03-22
 */
public interface IPaeaRiskItemService extends IService<PaeaRiskItem>
{
    /**
     * 查询预警
     *
     * @param id 预警ID
     * @return 预警
     */
    public PaeaRiskItem selectPaeaRiskItemById(String id);

    /**
     * 查询预警列表
     *
     * @param paeaRiskItem 预警
     * @return 预警集合
     */
    public List<PaeaRiskItem> selectPaeaRiskItemList(PaeaRiskItem paeaRiskItem);

    /**
     * 新增预警
     *
     * @param paeaRiskItem 预警
     * @return 结果
     */
    public int insertPaeaRiskItem(PaeaRiskItem paeaRiskItem);

    /**
     * 修改预警
     *
     * @param paeaRiskItem 预警
     * @return 结果
     */
    public int updatePaeaRiskItem(PaeaRiskItem paeaRiskItem);

    /**
     * 批量删除预警
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    public int deletePaeaRiskItemByIds(String ids);
    /**
     * 批量查询预警
     *
     * @param ids 需要查询的数据ID
     * @return 结果
     */
    public List<PaeaRiskItem> selectPaeaRiskItemByIds(String ids);
    public List<PaeaRiskItem> selectPaeaRiskItemsByInfoId(String riskInfoId);
    public List<PaeaRiskItem> selectPaeaRiskItemsByInfoIdAndBe(String riskInfoId);
    /**
     * 删除预警信息
     *
     * @param id 预警ID
     * @return 结果
     */
    public int deletePaeaRiskItemById(String id);

    public void init(ModelMap mmap);
    public List<PaeaRiskItem> queryRiskItem(PaeaRiskItemQuery paeaRiskItem, List<PaeaAuAuditFifldInfo> paeaAuAuditFifldInfos, String goupCode);
    public List<PaeaAuType>  selectPaeaAuTypesByCode(String code);
    public  String getAuditFifldInfoJson(String impType);
    public  String getAuditDetailFifldInfoJson(String impType);
    public  String getPaeaRiskItemNumModelJson(PaeaRiskItemQuery paeaRiskItemQuery);
    //创建差错基本信息
    public  AjaxResult getRegisteErrInfo(String riskInfoId);
    //导出
    public  String exportItem(PaeaRiskItemQuery paeaRiskItemQuery);
    public  String exportBatch(PaeaRiskItemQuery paeaRiskItemQuery);

    public String isByGroup(User user);
    public List<PaeaAuAuditFifldInfo> getAuAuditFifldInfo(String impType);
    public List<PaeaAuType> getPaeaAuType();
    //确认正常
    public AjaxResult doConfirm(String id);
    public AjaxResult doConfirmBatch(PaeaRiskItemQuery paeaRiskItemQuery,String ids);
    //批量下发差错
    public AjaxResult addRiskBatch(PaeaRiskItemQuery paeaRiskItemQuery,String ids,String auditSuggest,String paeaErPoints);
    //单笔下发差错回调更新
    public AjaxResult registerErrorUpItem(String itemId);
    //获取预警监督详情
    public AjaxResult getAuditProceeding(PaeaRiskItem paeaRiskItem);
    //获取预警数量
    public List<PaeaRiskItemNumModel> getPaeaRiskItemNumModel(User user, String beginDate, String endDate, String brCode, String impType);
    //查询子表
    public List<PaeaRiskItemDetail> queryPaeaRiskItemDetail(PaeaRiskItemDetail paeaRiskItemDetail);
}
